<!DOCTYPE html>
<html>
<head> 
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <title>爱家-房间信息</title>
    <link href="/static/plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet">
    <link href="/static/plugins/font-awesome/css/font-awesome.min.css" rel="stylesheet">
    <link href="/static/css/reset.css" rel="stylesheet">
    <link href="/static/plugins/swiper/css/swiper.min.css" rel="stylesheet">
    <link href="/static/plugins/bootstrap-datepicker/css/bootstrap-datepicker.min.css" rel="stylesheet">
    <link href="/static/css/ihome/main.css" rel="stylesheet">
    <link href="/static/css/ihome/detail.css" rel="stylesheet">
</head>
<body>
    <div class="container">
        <div class="top-bar">
            <div class="nav-bar">
                <h3 class="page-title">房间信息</h3>
                <a class="nav-btn fl" href="#" onclick="hrefBack();"><span><i class="fa fa-angle-left fa-2x"></i></span></a>
            </div>
        </div>

        <span id="house_detail"></span>

        <script id="detail" type="text/html">
        <div class="swiper-container">
            <ul class="swiper-wrapper">
                {{ each house.images as image }}
                <li class="swiper-slide"><img src="{{ image }}"></li>
                {{ /each }}
            </ul>
            <div class="swiper-pagination"></div>
            <div class="house-price">￥<span>{{ house.price }}</span>/晚</div>
        </div>
        <div class="detail-con">
            <div class="detail-header layout-style">
                <h2 class="house-title">{{ house.title }}</h2>
                <div class="landlord-pic"><img src="{{ house.user_avatar }}"></div>
                <h2 class="landlord-name">房东： <span>{{ house.user_name }}</span></h2>
            </div>
            <div class="house-info layout-style">
               <h3>房屋地址</h3>
               <ul class="house-info-list text-center">
                    <li>{{ house.address }}</li>
               </ul>
            </div>
            <ul class="house-type layout-style">
                <li>
                    <span class="icon-house"></span>
                    <div class="icon-text">
                        <h3>出租{{ house.room_count }}间</h3>
                        <p>房屋面积:{{ house.acreage }}平米</p>
                        <p>房屋户型:{{ house.unit }}</p>
                    </div>
                </li>
                <li>
                    <span class="icon-user"></span>
                    <div class="icon-text">
                        <h3>宜住{{ house.capacity }}人</h3>
                    </div>
                </li>
                <li>
                    <span class="icon-bed"></span>
                    <div class="icon-text">
                        <h3>卧床配置</h3>
                        <p>{{ house.beds }}</p>
                    </div>
                </li>
            </ul> 
            <div class="house-info layout-style">
                <h3>房间详情</h3>
                <ul class="house-info-list">
                    <li>收取押金<span>{{ house.deposit }}</span></li>
                    <li>最少入住天数<span>{{ house.min_days }}</span></li>
                    <li>最多入住天数<span>{{ if house.max_days==0 }}无限制{{ else }}{{ house.max_days }}{{ /if }}</span></li>
                </ul>
            </div>
            <div class="house-facility layout-style">
                <h3>配套设施</h3>
                <ul class="house-facility-list clearfix">
                    {{ each facility_list as facility }}
                    <li><span class="{{ if facility.id in house.facilities }}{{ facility.css }}{{ else }}jinzhi-ico{{ /if }}"></span>{{ facility.name }}</li>
                    {{ /each }}

                </ul>
            </div> 
            <div class="house-info layout-style">
                <h3>评价信息</h3>
                <ul class="house-comment-list">
                    <li>
                        <p>用户名<span class="fr">2016-11-11 20:00:00</span></p>
                        <p>感觉不错</p>
                    </li>
                </ul>
            </div>
        </div>
        <a class="book-house" href="/booking.html?id={{ house.id }}">即刻预定</a>
        </script>

        <div class="footer">
            <p><span><i class="fa fa-copyright"></i></span>爱家租房&nbsp;&nbsp;享受家的温馨</p>
        </div>
    </div>
    
    <script src="/static/js/jquery.min.js"></script>
    <script src="/static/plugins/bootstrap/js/bootstrap.min.js"></script>
    <script src="/static/plugins/swiper/js/swiper.jquery.min.js"></script>
    <script src="/static/plugins/bootstrap-datepicker/js/bootstrap-datepicker.min.js"></script>
    <script src="/static/plugins/bootstrap-datepicker/locales/bootstrap-datepicker.zh-CN.min.js"></script>
    <script src="/static/js/template.js"></script>
    <script src="/static/js/ihome/detail.js"></script>
</body>
</html>